import React from 'react'
import { Link, Switch } from "react-router-dom";

function Index(props) {
  console.log("Index props=>", props);
  return (
    <div>
      New首页
      <p>欢迎来到New首页</p>
      <div className="header">
        <Link to="/new/detail">detail</Link>
        <br />
        <Link to="/new/other">other</Link>
      </div>
      <div className="main">
        <Switch>
          {props.children}
        </Switch>
      </div>
    </div>
  )
}

export default Index
